package com.bite.rabbitmq.order.logisticsService.listener;


import com.bite.rabbitmq.order.orderService.model.OrderInfo;
import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

@Component
@RabbitListener(queues = "order.queue")
public class LogisticsListener {
    @RabbitHandler
    public void logisticsListener(String msg) {
        System.out.println("[订单信息获取]: " + msg);
    }

    @RabbitHandler
    public void logisticsListener2(OrderInfo orderInfo) {
        System.out.println("[订单信息获取]: " + orderInfo);
    }
}
